//
// Created by Administrator on 2021/7/10.
//

#include <iostream>

class Obj {
public:
    Obj() = default;
    Obj(int x) : num(x) {};
    bool operator==(const Obj &obj) const { return this->num == obj.num; }
    bool operator==(const int &x) const { return this->num == x; }
//    Obj &operator=(const Obj &obj) = default;
    friend Obj operator*(const Obj &obj1, const Obj &obj2);
    int num;
};

Obj operator*(const Obj &obj1, const Obj &obj2) {
    return obj1.num * obj2.num;
}

// const Class operator=(const Class &obj1, const Class &ojb2)
int main() {
    Obj obj1 = 1;
    Obj obj2 = 2;
    Obj obj3 = 3;
    Obj obj4{};
    obj4 = obj3;
    if (obj1 * obj2 == obj3) {
        std::cout << "yes" << std::endl;
    }
    if (obj1 * obj2 = obj3) {
        std::cout << "yes" << std::endl;
    }

    return 0;
}